<template>
    <div class="c-container">
        <div class="c-title">游戏列表

        </div>
        <div class="c-body">
            <div class="list-con">
                <div class="filter-con">
                    <div class="filter">扫雷
                        <span>+</span>
                    </div>
                </div>
                <div class="list-item">
                    <div>所属游戏</div>
                    <div class="small">层级id</div>
                    <div class="small">关卡名</div>
                    <div>时间奖励</div>
                    <div>完成奖励</div>
                    <div>消灭奖励</div>
                    <div>操作</div>
                </div>
                <div class="list-item">
                    <div>扫雷</div>
                    <div class="small">1</div>
                    <div class="small">简单</div>
                    <div>200</div>
                    <div>100</div>
                    <div>100</div>
                    <div>操作</div>
                </div>

            </div>
            <div class="list-page">
                <button>添加游戏关卡</button>
            </div>

        </div>
        <div class="c-popup" v-if="visible_edit">
            <EditProfile :data="data" :defaultIndex="defaultIndex" :hideEditFn="hideEditFn" />
        </div>
    </div>
</template>
<script>
import Axios from "axios";
export default {
    name: "userList",
    components: {

    },
    data() {
        return {
            data: []
        };
    },
    created() {

    },
    computed: {},
    methods: {

    }
};
</script>
<style lang='scss'>
.c-container {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  .c-title {
    width: 100%;
    height: 40px;
    border-bottom: 1px solid #ddd;
    display: flex;
    flex-direction: row;
    align-items: center;
  }
  .c-body {
    flex: 1;
    width: 100%;
    display: flex;
    flex-direction: column;
    .list-con {
      flex: 1;
      border: 1px solid #ddd;
      overflow-y: auto;
      .list-item {
        height: 40px;
        display: flex;
        flex-direction: row;
        background: #fefefe;
        > div {
          flex: 1;
          line-height: 40px;
          min-width: 80px;
          padding-left: 10px;
          box-sizing: border-box;
          overflow: hidden;
          text-overflow: ellipsis;
          &:nth-child(2n) {
            background: #f6f6f6;
          }
          > img {
            width: 40px;
            height: 40px;
            border-radius: 100%;
          }
        }
        .small {
          flex: none;
          text-align: center;
        }
        &:first-child {
          > div {
            text-align: center;
          }
        }
        &:nth-child(2n) {
          background: #f6f6f6;
          > div {
            &:nth-child(2n) {
              background: #fefefe;
            }
          }
        }
      }
    }
    .list-page {
      height: 40px;
    }
  }
  .c-popup {
    width: 100%;
    height: 100%;
    position: fixed;
    z-index: 100;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    .editProfile-popup {
      width: 400px;
      height: auto;
      padding: 10px;
      background: #00bcd4;
      .editProfile-title {
        height: 30px;
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        line-height: 30px;
      }
      .form-item {
        height: 26px;
        padding: 5px 0;
        display: flex;
        > label {
          width: 80px;
          height: inherit;
          display: flex;
          align-items: center;
        }
        > div {
          flex: 1;
          height: inherit;
          > input[type='text'] {
            flex: 1;
            height: inherit;
          }
        }
      }
      .form-btn {
        height: 40px;
        line-height: 40px;
      }
    }
  }
}
.filter-con {
  height: 40px;
  display: flex;
  align-items: center;
}
.filter {
  height: 20px;
  padding: 3px 8px;
  border-radius: 8px;
  display: inline;
  background: #ddd;
  vertical-align: middle;
  > span {
    width: 16px;
    height: 16px;
    margin-left: 5px;
    float: right;
    border-radius: 100%;
    line-height: 16px;
    text-align: center;
    transform: rotate(45deg);
    vertical-align: middle;
    transition: all 0.3s;
    &:hover {
      background: #fff;
    }
  }
}
</style>
